package com.hspedu.stringBuffer;
/*
 *@auther will
 *@version 1.0
 */

public class StringBuffer01 {
    public static void main(String[] args) {
        String str = "hello tom";
        StringBuffer stringBuffer = new StringBuffer(str);
        System.out.println(stringBuffer);

        StringBuffer stringBuffer1 = new StringBuffer();
        StringBuffer append = stringBuffer1.append(str);
        System.out.println(append);

        String s = append.toString();
        System.out.println(s);

        String s1 = new String(append);
        System.out.println(s1);
    }
}
